<!doctype html>
<html>

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <link rel="stylesheet" type="text/css" href="../../../css/aui.css" />
    <style>
        .aui-bar-nav {
            background: #0689FB;
        }
    </style>
</head>

<body>
    <header class="aui-bar aui-bar-nav" id="header">
        <a class="aui-btn aui-pull-left" tapmode onclick="close_w()">
            <span class="aui-iconfont aui-icon-left"></span>
        </a>
        <div class="aui-title">地址管理</div>
        <a class="aui-btn aui-pull-right aui-hide" tapmode onclick="confirm()">确认选中</a>
    </header>
    <footer class="aui-bar aui-bar-tab aui-btn-info" id="footer">
        <div class="aui-bar-tab-item aui-padded-l-15 aui-padded-r-15" onclick="add_addr()">
            <div class="aui-btn aui-btn-block aui-btn-sm aui-btn-info">添加地址</div>
        </div>
    </footer>
</body>
<script src="../../../script/api.js" charset="utf-8"></script>
<script src="../../../script/common/jquery-3.3.1.min.js" charset="utf-8"></script>
<script src="../../../script/common/common.js" charset="utf-8"></script>
<script src="../../../script/common/config.js" charset="utf-8"></script>
<script src="../../../script/common/vue.min.js" charset="utf-8"></script>
<script>
    apiready = function() {
        api.parseTapmode();
        if (api.pageParam && api.pageParam.type === 'select') {
            $('.aui-pull-right').removeClass('aui-hide');
        }
        openFrame();
    }

    function openFrame() {
        var name = "addr_frm";
        var url = "./addr_frm.html";
        open_f(name, url, api.pageParam);
    }

    function confirm() {
        api.execScript({
            frameName: 'addr_frm',
            script: 'vm.confirmAddr()'
        });
    }

    function add_addr() {
        var name = "add_addr_win";
        var url = "./add_addr_win.html";
        open_w(name, url, {
            type: 'add'
        });
    }
</script>

</html>
